<?php $this->_extends('../_layouts/default_layout'); ?>
<?php $this->_block('contents'); ?>
<script type="text/javascript">
$(function(){
	$(".datepicker").datepicker({dateFormat:'yy-mm-dd',changeMonth:true});
});
</script>
<fieldset><legend>查询条件</legend>
<form method="get">
<? include(Q::ini('custom_system/elements_dir') . 'searchform_element.php');?>
<table class="form_table">
<tr>
	<th>更新日期</th>
	<td>
		<input type="text" name="begin_time" class="datepicker" value="<?=isset($_GET['begin_time'])?$_GET['begin_time']:''?>" /> to 
		<input type="text" name="end_time" class="datepicker" value="<?=isset($_GET['end_time'])?$_GET['end_time']:''?>" />
	</td>
</tr>
<tr>
	<td><input type="hidden" name="is_search" value="1" /></td>
	<td><input type="submit" class="button" value="查询" /></td>
</tr>
</table>
</form></fieldset>
<?if (isset($_GET['is_search'])):?>
<table width="100%" class="list_table">
<tr>
	<th></th>
	<th colspan="3">清仓</th>
	<th colspan="3">卖完不卖</th>
</tr>
<tr>
	<th>更新日期</th>
	<th>SKU数</th>
	<th>总实际数</th>
	<th>货值</th>
	<th>SKU数</th>
	<th>总实际数</th>
	<th>货值</th>
</tr>
<?foreach ($data as $key => $d):?>
<tr>
	<td><?=$key?></td>
	<?foreach ($d as $k => $v):?>
	<td><?=$v['number_quantity']?></td>
	<td><?=$v['total_actual_quantity']?></td>
	<td><?=$v['total_value']?></td>
	<?endforeach;?>
</tr>
<?endforeach;?>
</table>
<?endif;?>
<?php $this->_endblock();?>